package com.teamin.mapper;

import com.teamin.entity.WxUserEntity;
import org.apache.ibatis.annotations.Param;

public interface WxUserMapper {

    int saveWxUserEntity(WxUserEntity wxUserEntity);

    /**
     * 根据小程序ID 查找用户信息
     * @param unionId
     * @return
     */
    WxUserEntity selectWxUserEntity(@Param("unionId") String unionId);
  
    int updateWxUserEntity(WxUserEntity wxUserEntity);


    WxUserEntity selectWxUserEntityByUser(@Param("userId") Long userId);

    /**
     * 取消公众号的关注
     */
    int cancleMPAttention(@Param("mpOpenId") String mpOpenId) ;

    /**
     * 是否存在UNIONID 的用户
     */
    Boolean existUnionId(@Param("unionId") String unionId) ;
}